package com.qianli.cashmama.trade.openApi.enums;

/**
 * @Author: cashmama
 * @Date: 2020/12/29-09:51
 * @Description:
 * @Slogan: To be or not to be
 **/
public enum MerchantCodeEnum {
    LOAN_BEE("LoanBee","T100011")
    ;

    private String code;
    private String thirdCode;

    MerchantCodeEnum(String code, String thirdCode) {
        this.code = code;
        this.thirdCode = thirdCode;
    }

    public String getCode() {
        return code;
    }

    public MerchantCodeEnum setCode(String code) {
        this.code = code;
        return this;
    }

    public String getThirdCode() {
        return thirdCode;
    }

    public MerchantCodeEnum setThirdCode(String thirdCode) {
        this.thirdCode = thirdCode;
        return this;
    }

    public static MerchantCodeEnum getThirdCode(String code) {
        MerchantCodeEnum orderStatusEnum = null;
        for (MerchantCodeEnum statusEnum : MerchantCodeEnum.values()) {
            if (statusEnum.getCode().equals(code)) {
                orderStatusEnum = statusEnum;
            }
        }
        return orderStatusEnum;
    }

}
